package com.uairobot.bill.websocket.chat.web.controller;

import java.util.Arrays;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.ApplicationContext;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("spring")
public class SpringController {

  @Autowired
  private ApplicationContext ac;

  @RequestMapping("beans")
  public String getBeans() {
    String retval = Arrays.toString(ac.getBeanDefinitionNames());
    System.out.println(retval);
    return retval;
  }
}
